package com;

import com.filter.AccessFilter;
import com.filter.PostFilter;
import com.filter.RouteFilter;
import org.springframework.boot.builder.SpringApplicationBuilder;
import org.springframework.cloud.client.SpringCloudApplication;
import org.springframework.cloud.netflix.zuul.EnableZuulProxy;
import org.springframework.context.annotation.Bean;

/**
 * Created by dell on 2016/9/22.
 */
@EnableZuulProxy
@SpringCloudApplication
public class AppZuul {

    public static void main(String[] args) {
        new SpringApplicationBuilder(AppZuul.class).web(true).run(args);
    }

    @Bean
    public AccessFilter accessFilter() {
        return new AccessFilter();
    }

    @Bean
    public RouteFilter routeFilter(){
        return new RouteFilter();
    }

    @Bean
    public PostFilter postFilter(){
        return new PostFilter();
    }
}
